<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>高德地图测试</title>
    <style>
        body, html {
            margin: 0;
            padding: 0;
            height: 100%;
        }
        #container {
            width: 100%;
            height: 500px;
        }
    </style>
</head>
<body>
    <h1>高德地图API测试</h1>
    <div id="container"></div>
    
    <script>
        // 动态加载高德地图API
        function loadAMapScript() {
            var script = document.createElement('script');
            script.type = 'text/javascript';
            script.src = 'https://webapi.amap.com/maps?v=2.0&key=73fbf010867aee81f74c91d3a77f4e05&callback=initMap';
            document.head.appendChild(script);
        }
        
        // 初始化地图
        function initMap() {
            var map = new AMap.Map('container', {
                zoom: 10,
                center: [119.95, 30.53] // 德清中心点
            });
            
            // 添加一个标记
            var marker = new AMap.Marker({
                position: [119.953931, 30.533385], // 如家酒店位置
                title: '如家丽岚睿柏云酒店'
            });
            
            map.add(marker);
            
            // 添加控件
            map.addControl(new AMap.Scale());
            map.addControl(new AMap.ToolBar());
        }
        
        // 加载地图
        loadAMapScript();
    </script>
</body>
</html> 